package com.cn.lp.export.plugin.common.log;

import com.cn.lp.export.log.LocalLogger;
import com.cn.lp.export.log.LocalLoggerFactory;
import com.cn.lp.export.log.logback.LogbackLocalLogger;
import com.cn.lp.export.output.Exportor;
import org.apache.maven.plugin.AbstractMojo;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/** 插件日志工厂 */
public class MavenLocalLoggerFactory implements LocalLoggerFactory {

    /** 插件类 */
    public AbstractMojo mojo;

    public MavenLocalLoggerFactory() {

    }
    
    public MavenLocalLoggerFactory(AbstractMojo mojo) {
        this.mojo = mojo;
    }

    @Override
    public LocalLogger create(Class<?> clazz) {
        return new MavenLocalLogger(mojo.getLog());
    }

}
